package com.lsh.oms.core.records.core;

import java.math.BigDecimal;
import java.util.List;
import java.util.Map;

public interface ReturnResult {

    Long id();

    String number();

    Status status();

    void paymentNotify(Map<String, Object> request);

    void start(Map<String, Object> request);

    void run(Map<String, Object> request);

    void issue(Map<String, Object> request);

    Map<String, List<Map<String, Object>>> relations();

    void updateActualAmount();

    enum Status {
        // 待审核
        PENDING,
        // 已完成
        TERMINATED
    }

    enum Responsibility {

        NONE, COMPANY, TENANT, DELIVERYMAN;
    }

    interface ReturnResultDetail {

        Long id();

        BigDecimal amount();

        boolean isWeighingGoods();

        BigDecimal quantity();

        BigDecimal realQuantity();

        Long returnResultId();

        BigDecimal actualAmount();

        void updateActualAmount();
    }
}
